<%@ page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%@ taglib prefix="sf" uri="http://www.springside.org.cn/tags/form" %>
<c:set var="ctx" value="${pageContext.request.contextPath}" />
<script>
	$(document).ready(function() {
		//聚焦第一个输入框
		$("#name").focus();
		//为inputForm注册validate函数
		$("#inputForm").validate();
	});
</script>
<div class="row-fluid">
	<div class="span12">
		<sf:form id="inputForm" commandName="attachment" cssClass="form-horizontal" action="create">
			<div class="control-group">
				<label class="control-label" for="fileType">FILE_TYPE:</label>
				<div class="controls">
				 <sf:select path="fileType" items="${fileTypeList }"/>
				</div>
			</div>	  
			<div class="control-group">
				<label class="control-label" for="url">URL:</label>
				<div class="controls">
					<sf:input path="url" cssClass="input-large required" />
				</div>
			</div>	  
			<div class="control-group">
				<label class="control-label" for="btnSave">&nbsp;</label>
				<div class="controls">
					<input id="btnSave" class="btn btn-primary" type="submit" value="Save"> 
					<input id="btnCancel" class="btn" type="button" value="Cancel" onclick="history.back()">
				</div>
			</div>
		</sf:form>
		
	</div><!-- span12 end -->
	
</div> <!-- row-fluid end -->
